﻿<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="ZodiacsEdit.ascx.cs"
    Inherits="Micronet.OpenWeb.OpenWeb.Admin.Views.Shared.OpenPersonality.ZodiacsEdit" %>
<owc:OwDetailsView ID="ZodiacsDv" runat="server" AutoGenerateRows="False" DataSourceID="ZodiacsOds" DataKeyNames="ZodiacID"
    EnableModelValidation="True" OwNotificationID="">
    <Fields>
        <asp:TemplateField>
            <InsertItemTemplate>
                <fieldset>
                    <legend>
                        <owc:OwR runat="server" OwText="GeneralInfo" /></legend>
                    <owac:OwDetailCommonGroup ID="OwDetailCommonGroup1" runat="server" OwBindLanguageValue='<%# Bind("LanguageCode") %>'
                        OwAuthorVisible="false" OwWardLocalityVisible="false" OwSourceVisible="false"
                        OwCategoryVisible="false" />
                </fieldset>
                <fieldset>
                    <legend>  <owc:OwR runat="server" OwText="InfoLabel" /></legend>
                    <table>
                        <tr>
                            <td>
                                <owc:OwR runat="server" OwText="Name" />
                            </td>
                            <td>
                                <owc:OwTextBox ID="NameTxt" runat="server" Text='<%# Bind("Name") %>' SkinID="OwTextBox" />
                                <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" Text="*" ErrorMessage="<%$OwR:NameNotEmpty %>"
                                    Display="Dynamic" ControlToValidate="NameTxt"></asp:RequiredFieldValidator>
                            </td>
                        </tr>
                        <tr>
                            <td>
                                <owc:OwR runat="server" OwText="IsEnabled" />
                            </td>
                            <td>
                                <owc:OwCheckBox ID="IsEnabledCb" runat="server" Checked='<%# Bind("IsEnabled") %>'
                                    SkinID="OwCheckBox" />
                        </tr>
                        <tr>
                            <td>
                                <owc:OwR runat="server" OwText="IsDeleted" />
                            </td>
                            <td>
                                <owc:OwCheckBox ID="IsDeleteCb" runat="server" Checked='<%# Bind("IsDeleted") %>'
                                    SkinID="OwCheckBox" />
                        </tr>
                        <tr>
                            <td>
                                <owc:OwR runat="server" OwText="StartDate" />
                            </td>
                            <td>
                                <owc:OwDateTimePicker SkinID="OwDateTimePickerAdmin" ClientEvents-OnDateSelected="showNotification"
                                    ID="StartDateDtpk" runat="server" Culture="en-US" DbSelectedDate='<%# Bind("StartDate") %>'
                                 OwDefaultValue='<%$ Ow: DateTime.Now %>'
                                    OwUsedForEdit="False">
                                
                                </owc:OwDateTimePicker>
                            </td>
                        </tr>
                        <tr>
                            <td>
                                <owc:OwR runat="server" OwText="EndDate" />
                            </td>
                            <td>
                               <owc:OwDateTimePicker SkinID="owDateTimePickerDetailAdmin" ClientEvents-OnDateSelected="showNotification"
                                    ID="EndDateDtpk" runat="server" Culture="en-US" DbSelectedDate='<%# Bind("EndDate") %>'
                                    MaxDate="12/31/9999 23:59:59" 
                                    OwUsedForEdit="False">
                                    <TimeView CellSpacing="-1">
                                    </TimeView>
                                    <TimePopupButton ImageUrl="" HoverImageUrl=""></TimePopupButton>
                                    <Calendar UseRowHeadersAsSelectors="False" UseColumnHeadersAsSelectors="False" ViewSelectorText="x">
                                    </Calendar>
                                    <DatePopupButton ImageUrl="" HoverImageUrl=""></DatePopupButton>
                                </owc:OwDateTimePicker>
                                
                                </owc:OwDateTimePicker>
                              <asp:CompareValidator ID="CompareValidator3" runat="server" ControlToCompare="StartDateDtpk"
                                    ControlToValidate="EndDateDtpk" ErrorMessage="<%$ OwR:EndGreaterThanEqualStartDate %>"
                                    ValidationGroup="VDGroup" Operator="GreaterThanEqual"></asp:CompareValidator>

                            </td>
                        </tr>
                        <tr>
                            <td>
                                <owc:OwR  runat="server" OwText="ThumbImage" />
                            </td>
                            <td>
                                <owc:OwEditor ID="ImagesEditor" runat="server" OwEditorType="OnlyInsertImage" OwBindValue='<%# Bind("ThumbImage") %>'
                                    SkinID="OwEditorInsertImageOnly" />
                            </td>
                        </tr>
                        <tr>
                            <td>
                                <owc:OwR runat="server" OwText="Description" />
                            </td>
                            <td>
                                <owc:OwEditor runat="server" ID="DescriptionEditor" SkinID="OwEditorBrief" Content='<%# Bind("Description") %>' />
                            </td>
                        </tr>
                    </table>
                </fieldset>
            </InsertItemTemplate>
            <EditItemTemplate>

             <fieldset>
                    <legend>
                        <owc:OwR runat="server" OwText="GeneralInfo" /></legend>
                    <owac:OwDetailCommonGroup ID="OwDetailCommonGroup1" runat="server" OwBindLanguageValue='<%# Bind("LanguageCode") %>'
                        OwAuthorVisible="false" OwWardLocalityVisible="false" OwSourceVisible="false"
                        OwCategoryVisible="false" />
                </fieldset>
                <fieldset>
                    <legend>  <owc:OwR runat="server" OwText="InfoLabel" /></legend>
                    <table>
                        <tr>
                            <td>
                                <owc:OwR runat="server" OwText="Name" />
                            </td>
                            <td>
                                <owc:OwTextBox ID="NameTxt" runat="server" Text='<%# Bind("Name") %>' SkinID="OwTextBox" />
                                 <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" Text="*" ErrorMessage="<%$OwR:NameNotEmpty %>"
                                    Display="Dynamic" ControlToValidate="NameTxt"></asp:RequiredFieldValidator>
                            </td>
                        </tr>
                        <tr>
                            <td>
                                <owc:OwR  runat="server" OwText="IsEnabled" />
                            </td>
                            <td>
                                <owc:OwCheckBox ID="IsEnabledCb" runat="server" Checked='<%# Bind("IsEnabled") %>'
                                    SkinID="OwCheckBox" />
                        </tr>
                        <tr>
                            <td>
                                <owc:OwR runat="server" OwText="IsDeleted" />
                            </td>
                            <td>
                                <owc:OwCheckBox ID="IsDeleteCb" runat="server" Checked='<%# Bind("IsDeleted") %>'
                                    SkinID="OwCheckBox" />
                        </tr>
                        <tr>
                            <td>
                                <owc:OwR runat="server" OwText="StartDate" />
                            </td>
                            <td>
                                <owc:OwDateTimePicker SkinID="owDateTimePickerDetailAdmin" ClientEvents-OnDateSelected="showNotification"
                                    ID="StartDateDtpk" runat="server" Culture="en-US" DbSelectedDate='<%# Bind("StartDate") %>'
                                    MaxDate="12/31/9999 23:59:59" MinDate="" OwDefaultValue='<%$ Ow: DateTime.Now %>'
                                    OwUsedForEdit="False">
                                    <TimeView CellSpacing="-1">
                                    </TimeView>
                                    <TimePopupButton ImageUrl="" HoverImageUrl=""></TimePopupButton>
                                    <Calendar UseRowHeadersAsSelectors="False" UseColumnHeadersAsSelectors="False" ViewSelectorText="x">
                                    </Calendar>
                                    <DatePopupButton ImageUrl="" HoverImageUrl=""></DatePopupButton>
                                </owc:OwDateTimePicker>
                            </td>
                        </tr>
                        <tr>
                            <td>
                                <owc:OwR runat="server" OwText="EndDate" />
                            </td>
                            <td>
                                <owc:OwDateTimePicker SkinID="owDateTimePickerDetailAdmin" ClientEvents-OnDateSelected="showNotification"
                                    ID="EndDateDtpk" runat="server" Culture="en-US" DbSelectedDate='<%# Bind("EndDate") %>'
                                    MaxDate="12/31/9999 23:59:59" 
                                    OwUsedForEdit="False">
                                    <TimeView CellSpacing="-1">
                                    </TimeView>
                                    <TimePopupButton ImageUrl="" HoverImageUrl=""></TimePopupButton>
                                    <Calendar UseRowHeadersAsSelectors="False" UseColumnHeadersAsSelectors="False" ViewSelectorText="x">
                                    </Calendar>
                                    <DatePopupButton ImageUrl="" HoverImageUrl=""></DatePopupButton>
                                </owc:OwDateTimePicker>
                               <asp:CompareValidator ID="CompareValidator3" runat="server" ControlToCompare="StartDateDtpk"
                                    ControlToValidate="EndDateDtpk" ErrorMessage="<%$ OwR:EndGreaterThanEqualStartDate %>"
                                    ValidationGroup="VDGroup" Operator="GreaterThanEqual"></asp:CompareValidator>
                            </td>
                        </tr>
                        <tr>
                            <td>
                                <owc:OwR  runat="server" OwText="ThumbImage" />
                            </td>
                            <td>
                                <owc:OwEditor ID="ImagesEditor" runat="server" OwEditorType="OnlyInsertImage" OwBindValue='<%# Bind("ThumbImage") %>'
                                    SkinID="OwEditorInsertImageOnly" Content='<%# String.Format("<img src={0} />",Eval("ThumbImage")) %>' />
                            </td>
                        </tr>
                        <tr>
                            <td>
                                <owc:OwR  runat="server" OwText="Description" />
                            </td>
                            <td>
                                <owc:OwEditor runat="server" ID="DescriptionEditor" SkinID="OwEditorBrief" Content='<%# Bind("Description") %>' />
                            </td>
                        </tr>
                    </table>
                </fieldset>

            </EditItemTemplate>
        </asp:TemplateField>
        <asp:TemplateField ShowHeader="False">
            <EditItemTemplate>
                <fieldset style="position: fixed; bottom: 0px; right: 0px; width: 100%">
                    <legend>
                        <asp:Label ID="Label4" runat="server" EnableViewState="false" Text="<%$ OwR: Action %>" /></legend>
                    <owc:OwButton ID="EditUpdateThenCloseButton" runat="server" CommandName="Update"
                        Text='<%$OwR:Update %>' OnClientClicking="showNotification">
                    </owc:OwButton>
                    &nbsp;
                    <owc:OwConfirmButton ID="EditDeleteButton" runat="server" CausesValidation="True"
                        CommandName="Delete" Text="<%$OwR:Delete %>" SkinID="OwConfirmButton">
                    </owc:OwConfirmButton>
                    &nbsp;<owc:OwButton ID="EditCancelButton" runat="server" CausesValidation="False"
                        CommandName="Cancel" Text="<%$OwR:Cancel %>">
                    </owc:OwButton>
                </fieldset>
            </EditItemTemplate>
            <InsertItemTemplate>
                <fieldset style="position: fixed; bottom: 0px; right: 0px; width: 100%">
                    <legend>
                        <asp:Label ID="Label4" runat="server" EnableViewState="false" Text="<%$ OwR: Action %>" /></legend>
                    <owc:OwButton ID="InsertInsertButton" runat="server" CommandName="Insert" Text="<%$OwR:Insert %>"
                        OnClientClicking="showNotification">
                    </owc:OwButton>
                    &nbsp;<owc:OwButton ID="InsertCancelButton" runat="server" CausesValidation="False"
                        CommandName="Cancel" Text="<%$OwR:Cancel %>">
                    </owc:OwButton>
                </fieldset>
            </InsertItemTemplate>
        </asp:TemplateField>
    </Fields>
</owc:OwDetailsView>
<owc:OwObjectDataSource ID="ZodiacsOds" runat="server" DataObjectTypeName="Micronet.OpenWeb.Entity.OwZodiacsEntity"
    DeleteMethod="OwDelete" InsertMethod="OwInsert" OldValuesParameterFormatString="original_{0}"
    SelectMethod="OwGetEntity" TypeName="Micronet.OpenWeb.Com.BLL.OwZodiacsBLL" UpdateMethod="OwUpdate">
    <SelectParameters>
        <asp:QueryStringParameter Name="zodiacID" QueryStringField="Id" Type="Int64" />
    </SelectParameters>
</owc:OwObjectDataSource>
